home *** CD-ROM | disk | FTP | other *** search
/ Skunkware 98 / Skunkware 98.iso / src / mail / smail-3.2.tar.gz / smail-3.2.tar / smail-3.2 / INSTALL < prev    next >
Text File  |  1996-06-14  |  20KB  |  439 lines

  1. #ident    "@(#)smail:RELEASE-3_2:INSTALL,v 1.7 1996/06/14 19:00:13 woods Exp"
  2.  
  3. INITIAL UNPACKING
  4.  
  5. After you've unpacked the source (and thus been able to read this far in
  6. this file), we strongly recommend you begin by first checking the entire
  7. distribution into some form of source code control system.  We heartily
  8. recommend the use of CVS, as it offers what is called "vendor branch
  9. support" thus making it trivial to merge local changes with new "vendor"
  10. releases of a product.  It will also make it far easier for you to
  11. submit accurate patches to the smail developer(s) (see below for
  12. information about submitting patches).
  13.  
  14. To check this release of smail into CVS (assuming you alread have CVS
  15. installed and a default repository created) you might do something like
  16. this:
  17.  
  18.     cvs import -I ! -m 'Smail Version 3.2 Distribution' smail SMAIL SMAIL-3_2
  19.  
  20. If you don't have CVS, but are familiar with RCS, or SCCS, you can also
  21. use those tools to track any local changes you might make during the
  22. course of installation and configuration of smail.
  23.  
  24. If you do you CVS, you should not run "make depend", or if you do you
  25. should not check in the changed Makefiles.  If you wish to / need to
  26. make local changes to the Makefiles, you should do so in a freshly
  27. checked out working directory, and *not* run "make depend", but rather
  28. run "make clobber" between builds.  Once you've verified and checked in
  29. your changes, you may then run "make depend" to speed subsequent builds,
  30. but remember *not* to check in the Makefiles with the dependencies.
  31.  
  32.  
  33. CONFIGURATION
  34.  
  35. We recommend that you read through the various manual pages before
  36. setting up and installing smail.  To generate the manual pages, change to
  37. the man directory and type "make".  This will generate manual pages for
  38. the default smail configuration.  Detailed information on smail can be
  39. found in the manual pages smail(5) and smail(8), with further details on
  40. the specific configuration files in the other section 5 manual pages..
  41.  
  42. All run-time configuration files are optional, and the smail program
  43. itself creates anything that it absolutely needs.  Thus in the
  44. simplest example, the installation procedure is simply to setup the
  45. base internal configuration and type the various make commands.
  46.  
  47. The only file that you must edit is conf/EDITME, which drives the
  48. compilation process for the smail binary and the several accompanying
  49. utilities.  This file describes the locations of various files and
  50. directories, enables or disables various capabilities, and points to a
  51. file describing your architecture and operating system.  It should be
  52. copied from the source file conf/EDITME-dist, or from one of the small
  53. example files (conf/EDITME-*) if one happens to nearly match your
  54. system.  Note that if you generated the smail manual pages, the
  55. conf/EDITME file will have already been created for you, though you
  56. should still review and edit it or replace it with one of the other
  57. simple examples.
  58.  
  59. Future patches to smail will be applied to conf/EDITME-dist (and the
  60. examples) and it will be your responsibility to make sure that these
  61. changes are reflected in conf/EDITME, as needed.  (This is one place
  62. where source code control tools such as RCS, or SCCS might be most
  63. useful.  CVS keeps track of the entire project, of course.)
  64.  
  65. The full conf/EDITME-dist mentions just about every compilation and
  66. installation option available in smail.  It appears to be very large and
  67. complex at first glance.  However you'll see some tiny sample
  68. configurations in other files named conf/EDITME-*.  These files are
  69. actual working configurations used for production systems.  In general
  70. the configuration system is set up in such a way that if you define only
  71. the compiler flags (CPPFLAGS, CFLAGS, LDFLAGS, etc.), and set the
  72. OS_TYPE, smail will build and install as if it were to be the native
  73. vendor-supplied mailer for the system, and will attempt to mimic (and
  74. thus replace) a sendmail installation in terms of the command-line
  75. interface and standard supplementary files such as the aliases table.
  76.  
  77. Some sites may also need to create (or fix) an operating system
  78. description file.  To do this, change to the conf/os directory and copy
  79. the file "template" to a name descriptive of your operating system.
  80. Then edit the copy as appropriate.  The basename of this file can then
  81. be used as a value for the OS_TYPE variable in the conf/EDITME file.  If
  82. you create a new operating system description file, please mail it to us
  83. so that we may add it to the distribution.
  84.  
  85. A simple way to test smail is to set the variable TEST_BASE in the
  86. conf/EDITME file to a test installation directory.  A "make install"
  87. will create a tree under this directory, with all of the smail binaries
  88. and utilities.  Smail can then be tested in this directory without
  89. affecting the operation of any other mailers currently working on your
  90. system, including a previous installation of smail itself.
  91.  
  92. If you're trying to debug an EDITME file, or an OS_TYPE file, you can
  93. simply generate defs.* files in the conf directory by running the
  94. following command from within the conf directory:
  95.  
  96.       ROOT=.. sh lib/mkdefs.sh
  97.  
  98.  
  99. BUILDING AND INSTALLATION
  100.  
  101. NOTE:  You should probably do a test build install before installing
  102.        smail onto a live system.  To do this, setup the TEST_BASE
  103.        variable as described above, and go through the steps in this
  104.        section.  Then, to install on to a live system, comment out
  105.        TEST_BASE in the conf/EDITME file and perform these steps again.
  106.        The second time around, it will not be necessary to build the
  107.        makefile dependencies.
  108.  
  109. When everything is setup, you may optionally create the Makefile
  110. dependencies for your system and configuration.  To do this, type:
  111.  
  112.     make -k depend 2>&1 | tee mkdep.out
  113.  
  114. If you are a C shell or tcsh user (poor you!), try:
  115.  
  116.     make -k depend |& tee mkdep.out
  117.  
  118. at the top of the smail source tree.  Scan the output produced by for
  119. any errors.  In particular, watch out for missing include files.  If any
  120. messages about missing include files are generated, please send us mail
  121. describing your operating system and the name of the include file which
  122. was not found (you should also enclose your conf/EDITME file, and any
  123. conf/os file you might have modified and be using for the failed build.
  124. Please tell us of any similarly named include files which DO exist,
  125. which may be used instead.  Building the dependencies takes 34 seconds
  126. on an unloaded Amdahl 5890, about 6 and a half minutes on a Sun-3/280,
  127. and can it take up to half an hour or more on smaller machines.
  128.  
  129. WARNING:  If you do not run "make depend", you should be aware that
  130. you'll likely have to run "make clobber" if you change anything between
  131. builds to ensure everything is properly up to date.  This applies
  132. especially to changes in the conf/EDITME file.
  133.  
  134. When the dependencies have been generated, build the binaries, utilities
  135. and localized manual pages with the command:
  136.  
  137.     make 2>&1 | tee mk.out
  138.  
  139. or for those stuck on csh:
  140.  
  141.     make |& tee mk.out
  142.  
  143. This may take a while.  The complete build takes 1 minute and 30 seconds
  144. on an unloaded Amdahl 5890 (with optimizing turned on), about 4 minutes
  145. on a P120 w/ PCI SCSI running NetBSD-1.1A, and about 15 minutes in ./src
  146. on a Sun-3/280 with -g, or 32 minutes from the root with -O [SunOS-4.1
  147. /usr/5bin/cc].  A 16MB Sun3/260 running NetBSD-1.1-P2 takes about 55
  148. minutes with the source on NFS.  When building on a Symmetric-S/375 you
  149. can go off and do something else for a while, and check on it every ten
  150. minutes or so.  Even a 468dx66 PCI machine running NetBSD-1.1 can take a
  151. long time (75 min) if it has only 4Mb RAM and a cheap 500Mb IDE drive.
  152. The build takes about 2 hours on Fortune 32:16.
  153.  
  154.  
  155. If any errors were encountered, please mail them to us.  Please send a
  156. complete copy of the mk.out file, and a copy of your conf/EDITME file
  157. along with a "patch" (i.e. context diff) of any changes you've made to
  158. the official distribution sources.  In particular if you wrote your own
  159. operating system configuration file, please send that, too.  If you have
  160. any comments, or if you have your own fixes, please send those as well.
  161.  
  162. When smail builds correctly, install it by typing:
  163.  
  164.     make install
  165.  
  166. To install the manual pages as well, type:
  167.  
  168.     make installman
  169.  
  170. WARNING:  If you had installed the manual pages for a previous
  171. development release of smail (i.e. one which included routers.5,
  172. transports.5, config.5, etc.), you should remove these old manual pages
  173. from the destination directory.  These manual pages have been renamed to
  174. have the prefix "smail" as part of their names.
  175.  
  176. These commands may be typed in any individual directory, as well, to
  177. build or install within a limited context.  Most make command at any
  178. level within the tree will descend to lower levels within the source
  179. hierarchy and execute the same make command.
  180.  
  181. The following additional make commands can be useful:
  182.  
  183.     make clean    - to clear out make intermediate files.
  184.     make clobber    - to clean intermediate and target files.
  185.     make local_depend
  186.             - make dependencies in the local makefile but do
  187.               not descend into subdirectories.
  188.  
  189.  
  190. GENERAL COMPILATION NOTES
  191.  
  192. On ISC's Interactive UNIX (aka 386/ix), and probably on other systems as
  193. well, if you don't use an ANSI C compiler you will get the following
  194. messages while compiling:
  195.  
  196.     ../../util/dbm_compat.h: 13: bad include syntax
  197.     ../../util/dbm_compat.h: 22: bad include syntax
  198.  
  199. Ignore these messages.  They result from an #ifdef'd out:
  200.  
  201.     #include DBM_INCLUDE
  202.  
  203. where the C compiler does not allow macros to name include files.  This
  204. doesn't cause any problems when compiling on Interactive, beyond the
  205. generation of the above messages.  If your compiler really bombs out,
  206. remove the offending lines from util/dbm_compat.h.
  207.  
  208. Smail now makes use of some C data types which may not be defined in the
  209. standard system headers on some older systems.  These include "time_t",
  210. "off_t", "size_t", and the like.  If you get compiler errors related to
  211. definitions or declarations related to these data types, you may be able
  212. to work around the problem by adding appropriate #define statements in
  213. the MISC_DEFINES clause of your conf/EDITME file.  Please see the
  214. instructions in conf/EDITME-dist to see how the syntax for this usage
  215. might work, and consult your system manuals for the appropriate basic
  216. types to substitute for these standard types.
  217.  
  218.  
  219. SYSTEM-SPECIFIC CAVEATS
  220.  
  221.  *  There have been reports that some versions of sed(1) [in particular
  222.     the one supplied with HP/UX 9.x and possibly earlier HP/UX versions
  223.     too] cannot handle the number of expressions in the defs.sed files
  224.     produced by the mkdefs script.  The easy work-around is to install a
  225.     more capable version of sed that doesn't trip over this limit, such
  226.     as the GNU Sed.  No other fixes are expected or desired as this
  227.     problem will hopefully be moot with the intended conversion to GNU
  228.     Autoconf.
  229.  
  230.  *  On MIPS systems, and possibily on other dual-universe systems, be sure
  231.     to set the BSD and System V timezones to the same value.  For MIPS
  232.     systems, the System V timezone is in /etc/TIMEZONE.  The timezone value
  233.     used by BSD routines is stored in the kernel and is set by the date
  234.     command.  For example, if you are in the Pacific timezone, set
  235.     /etc/TIMEZONE to:
  236.  
  237.     TZ=PST8PDT
  238.     export TZ
  239.  
  240.     and set the kernel timezone with:
  241.  
  242.     date -t 480
  243.  
  244.     At least one user was surprised to find smail using a different timezone
  245.     than some other commands.
  246.  
  247.  
  248. CREATING CONFIGURATION FILES
  249.  
  250. If you have need of a more complex configuration than can be provided
  251. with the internal defaults, read over the manual pages carefully.  We
  252. believe that the process of writing files is reasonably straightforward,
  253. though if you have any questions, or if you dispute this claim, please
  254. send mail to the smail3-users list mentioned in the README.  Sample
  255. configuration files can be found in the directory samples [WARNING:
  256. these files are very much out of date].  The complete current
  257. configuration can be displayed with the command "smail -v -bP ALL".  Of
  258. course if you run this command without any config files, it will display
  259. the default compiled in configuration.
  260.  
  261.  
  262. SMAIL ON THE INTERNET (VERY IMPORTANT FOR INTERNET USERS)
  263.  
  264. Users on the Internet should configure smail to use the Domain Name
  265. Service for routing on the Internet.  To use the DNS, you will have to
  266. have the bind resolver library, and you will have to tell smail that you
  267. have it.  For some systems, these are configured into smail by default.
  268. For other systems, you will need to configure in the bind router driver
  269. by modifying the EDITME file.  This involves adding the setting:
  270.  
  271.     DRIVER_CONFIGURATION=arpa-network
  272.  
  273. and adding "BIND" to the HAVE list.  See the EDITME file in the conf
  274. directory for more details.
  275.  
  276.  
  277. SMAIL WITH SYSTEM V RELEASE 2&3 AND SUNOS-4
  278.  
  279. SunOS-4 and System V Release 2&3 systems typically have a /bin/mail
  280. program that both delivers mail and reads mail.  Smail provides a
  281. replacement for the /bin/mail program, in pd/binmail, that uses the old
  282. /bin/mail for reading mail, and smail for delivering mail.  To use the
  283. replacement /bin/mail, you will need to define the LMAIL variable in
  284. conf/EDITME.  See conf/EDITME for more instructions.
  285.  
  286. The System V mailx utility will need to be updated to know how to find
  287. smail.  Presuming that smail is installed as /usr/lib/sendmail, you
  288. will need to add the following line to the file /usr/lib/mailx/mailx.rc:
  289.  
  290.     set sendmail=/usr/lib/sendmail
  291.  
  292. The SunOS-4 Mail utility already has this defined.
  293.  
  294. In any case you should ensure that /usr/lib/sendmail is included in
  295. conf/EDITME as either the value for SMAIL_NAME, or is included in the
  296. OTHER_SMAIL_NAMES setting.  For example on SunOS-4:
  297.  
  298.     OTHER_SMAIL_NAMES=/usr/lib/sendmail:/usr/ucb/mailq
  299.  
  300.  
  301. SMAIL AND SCO UNIX
  302.  
  303. Smail under SCO UNIX should be installed as both /bin/mail and
  304. /usr/lib/mail/execmail.  To do this, set OTHER_SMAIL_NAMES in the
  305. conf/EDITME file to "/bin/rmail:/usr/lib/mail/execmail".  You will also
  306. need to use the /bin/mail replacement in pd/binmail, just as in System
  307. V.  Some newer SCO UNIX systems also have a /usr/bin/rmail, as a link to
  308. /usr/bin/mailx.  This link should be deleted.
  309.  
  310. Some versions of SCO UNIX store mail messages in /usr/spool/mail,
  311. while others use /usr/mail, like System V.  If your system uses
  312. /usr/spool/mail, you will need to add the following line to the
  313. conf/EDITME file:
  314.  
  315.     MAILBOX_DIR=/usr/spool/mail
  316.  
  317. Current SCO releases use MMDF mailbox file formats.  Many users prefer
  318. to use public domain mail readers, such as elm or mush, that can be
  319. configured to use regular UNIX mailbox files.  Users that wish to be
  320. compatible with the MMDF mailbox file format must create a transports
  321. file that configures a prefix of "\1\1\1\1" to insert before each
  322. message stored in mailbox files.  Copy the file
  323. samples/generic/transports to the /usr/lib/smail directory, and modify
  324. it as suggested at the top of the file.
  325.  
  326. The SCO MMDF version of mailx supplies its own From: line using a
  327. hostname taken from an MMDF configuration file.  I have no idea why
  328. they decided it was a good idea to hard-code the hostname in a
  329. configuration file, but they did.  Thus, if you change your hostname,
  330. your From: lines won't change until you change the MMDF configuration
  331. file.  To correct the From: line change the MLDOMAIN and MLNAME
  332. definitions in /usr/mmdf/mmdftailor.
  333.  
  334. To get the MMDF-ified SCO to call smail from /bin/mail and mailx,
  335. add the line:
  336.  
  337.     set execmail
  338.  
  339. to the file /usr/lib/mail/mailrc.
  340.  
  341.  
  342. SMAIL AND SYSTEM V RELEASE 4
  343.  
  344. On many SVR4 implementations the mailbox file format defines a
  345. Content-Length field that indicates the length of each message, in
  346. bytes.  This obviates the need for inserting "> before lines beginning
  347. with "From " (and indeed, there are some problems with the AT&T-supplied
  348. version of mailx concerning message splitting, if you don't use the
  349. Content-Length header).  Smail can be configured to generated
  350. Content-Length fields (and Content-Type fields).  However, the
  351. compiled-in transports cannot do this.  To configure generation of these
  352. fields, copy the file samples/generic/transports to the /usr/lib/smail
  353. directory, and modify it as suggested at the top of the file.
  354.  
  355. In SVR4 the uux command is given message grades by using long names,
  356. which differs from older versions of HoneyDanBer UUCP, where message
  357. grades were a single character.  Smail does not support these longer
  358. names.  Fortunately, you can configure SVR4 to support single
  359. character message grades.  To make SVR4 compatible with smail, add the
  360. following lines to your /etc/uucp/Grades file:
  361.  
  362. 9    9    Any    User    Any
  363. A    A    Any    User    Any
  364. C    C    Any    User    Any
  365. a    a    Any    User    Any
  366. n    n    Any    User    Any
  367.  
  368. This list is sufficient for the default list of Precedence header
  369. field values supported by smail.
  370.  
  371. It is possible to configure an SVR4 system to call smail by replacing
  372. the file /etc/mail/mailsurr with the line:
  373.  
  374.     '(.+)'    '(.+)'    '< /usr/local/smail/bin/smail -em -i \\2'
  375.  
  376. This works, but it has the annoying side effect of invoking smail
  377. multiple times for each address given as an argument to /bin/mail or
  378. /bin/rmail.  It is preferable to replace /bin/rmail with smail, and to
  379. replace /bin/mail with the mail program supplied in pd/binmail.
  380.  
  381. To configure SVR4 to use smail for handling SMTP, move the file
  382. /etc/rc2.d/S88smtpd to /etc/rc2.d/no-S88smtpd, move the file
  383. /etc/rc0.d/K74smtpd to /etc/rc0.d/no-S74smtpd, and then add a new file
  384. /etc/rc2.d/S88smail containing:
  385.  
  386.     /usr/lib/sendmail -bd -q30m
  387.  
  388. Then, kill any existing smtpd program and start smail by executing the
  389. above command.
  390.  
  391. To convert an SVR4.2 system create the same file above, remove the
  392. smtpd entry in /etc/inetd.conf, then execute the following commands:
  393.  
  394.     sacadm -k -p inetd
  395.     sacadm -s -p inetd
  396.     /usr/lib/sendmail -bd -q30m
  397.  
  398.  
  399. SMAIL AND 4.3BSD OR ULTRIX
  400.  
  401. Some versions of Ultrix, plus stock 4.3BSD, have had problems in with
  402. some shell scripts supplied with smail.  We have made some attempts to
  403. simplify the offending shell scripts to avoid problems.  However, if
  404. errors are still encountered with /bin/sh, then use a different shell,
  405. such as ksh, zsh, pdksh, or bash, by compiling and installing smail with
  406. commands like:
  407.  
  408.     make SHELL=/bin/ksh depend
  409.     make SHELL=/bin/ksh all
  410.     make SHELL=/bin/ksh install
  411.  
  412. Some problems have also been reported with /bin/sh on Xenix.  I don't
  413. know if there is an alternate shell available on Xenix.  However,
  414. pdksh should compile and run there.  I realize that it seems absurd
  415. that regular /bin/sh cannot be used on some systems.  Hopefully the
  416. specific problems encountered can be found and remedied for future
  417. releases.
  418.  
  419.  
  420. RFC1413 SUPPORT
  421.  
  422. Smail contains support for RFC1413 identification of incoming SMTP/TCP
  423. traffic.  This allows tracking of who sent mail within a trusting
  424. community.  (By "trusting community", we mean that if you don't trust
  425. root on the sending system then you cannot trust the RFC1413 ident
  426. info supplied by the sending system.)
  427.  
  428. The support is via the libident library, which is not part of the
  429. smail package.  libident, currently at version 0.18 (October 5, 1995),
  430. is available from a number of sites (use archie) or from the master
  431. site by anonymous FTP from ftp.lysator.liu.se in /pub/ident/libs
  432. This site also has information about RFC1413, servers for RFC1413 and
  433. all sorts of other ident related goodies.
  434.  
  435. When you have the library code, you must compile it, and put the library
  436. somewhere where it will be seen by the linker (or use the "-I" and "-L"
  437. switches in EDITME for CFLAGS and LDFLAGS respectively).  Change EDITME
  438. to define "RFC1413" in the HAVE lines and add "-libident" to the LIBS.
  439.